package cn.bigcontainer.alt.sys.controller;

import javax.annotation.Resource;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.SessionAttributes;

import cn.bigcontainer.alt.sys.service.SysXiaoxiService;
import cn.bigcontainer.alt.sys.util.SysConstant;

/**
 * 消息的Controller类，用于处理用户请求.
 *
 * @author jiaod
 * @date 2020-03-24
 */
@Controller
@SessionAttributes(SysConstant.SESSION_USER)
@RequestMapping("/sys/xiaoxi")
public class SysXiaoxiController {

	@Resource
	private SysXiaoxiService sysXiaoxiService;
	
	/**
	 * 加载回复页面
	 * @param app
	 * @param selectedIds 被回复消息id
	 * @param req
	 * @param map
	 * @return
	@RequestMapping("/reply")
	public String loadReplyForm(MAppDto app, String selectedIds, @RequestParam Map<String, Object> req, Map<String, Object> map) {
		MViewDto form = sysXiaoxiService.loadReplyForm (app.getId(), selectedIds, req);
		form.getApp().setDomprefix(app.getDomprefix());
		map.put("form", form);
		return "meta/form";
	}
	 */
	
	/**
	 * 加载回复所有页面
	 * @param app
	 * @param selectedIds 被回复消息id
	 * @param req
	 * @param map
	 * @return
	@RequestMapping("/replyall")
	public String loadReplyAllForm(MAppDto app, String selectedIds, @RequestParam Map<String, Object> req, Map<String, Object> map) {
		MViewDto form = sysXiaoxiService.loadReplyAllForm (app.getId(), selectedIds, req);
		form.getApp().setDomprefix(app.getDomprefix());
		map.put("form", form);
		return "meta/form";
	}
	 */
}
